[Slack Alert] Tiktok UTM Check

Use this automation to check that the correct UTM parameters are used for all of your active Tiktok ads. For any ad that doesn’t follow your best practices, you will receive a Slack notification.

If you are looking for a way to check if your URLs are following a specific pattern, this automation is for you. Get a Slack message for any ads that don’t follow your UTM tracking structure.

Notion image

JSON Recipe

Import the automation recipe(s) into your own account. Don’t know how? Learn here.

Tiktok UTM Check
{"name":"[Slack Alert] Tiktok UTM Check","description":"tt_utm_check_20230314","nodes":{"for_each_v2_1":{"type":"for_each_v2","logging_enabled":false,"x":422,"y":480},"if_v2_1":{"type":"if_v2","logging_enabled":false,"x":1157,"y":478,"inputs":{"b":{"export_enabled":true,"data":[]},"condition":{"export_enabled":true,"data":"not_equal"}}},"delay_1":{"type":"delay","logging_enabled":false,"x":43,"y":739,"inputs":{"duration":{"export_enabled":true,"data":3600}}},"input_any_1":{"type":"input_any","logging_enabled":false,"x":751,"y":43,"group":"group_1","inputs":{"any":{"export_enabled":true,"data":[{"op":"add","path":"/root","value":{}},{"op":"move","path":"/root/url","from":"/landing_page_url"},{"op":"add","path":"/root/id","value":{"provider":"tiktok","type":"ad"}},{"op":"move","path":"/root/id/id","from":"/ad_id"},{"op":"add","path":"/root/id/context/adgroup_id","value":{"provider":"tiktok","type":"ad_group"}},{"op":"move","path":"/root/id/context/adgroup_id/id","from":"/adgroup_id"},{"op":"move","path":"/root/id/context/advertiser_id","from":"/advertiser_id"},{"op":"move","path":"/root/id/context/ad_name","from":"/ad_name"},{"op":"move","path":"","from":"/root"}]}}},"build_pattern_v2_1":{"type":"build_pattern_v2","logging_enabled":false,"x":234,"y":263,"group":"group_2","inputs":{"patterns":{"export_enabled":true,"data":[{"description":"UTM Source","regex":"utm_source=tiktok"},{"regex":"utm_medium=cpc","description":"UTM Medium"},{"regex":"utm_campaign=__CAMPAIGN_NAME__","description":"UTM Campaign"},{"regex":"utm_content=__CID_NAME__","description":"UTM Content"},{"regex":"utm_term=__AID_NAME__","description":"UTM Term"},{"description":"UTM Placement","regex":"utm_placement=__PLACEMENT__"}]}}},"filter_v2_1":{"type":"filter_v2","logging_enabled":false,"x":1125,"y":428,"group":"group_2","inputs":{"filters":{"export_enabled":true,"data":[{"value":false,"pointer":"/valid","operator":"="}]}}},"slack_select_conversation_id_1":{"type":"slack_select_conversation_id","logging_enabled":false,"x":317,"y":272,"group":"group_3","inputs":{"conversation_id":{"title":"conversation_id","description":"Select a Slack Channel or Conversation"}}},"slack_notifier_v2_1":{"type":"slack_notifier_v2","logging_enabled":false,"x":660,"y":447,"group":"group_3","inputs":{"blocks":{"export_enabled":true,"data":[{"type":"section","text":{"type":"mrkdwn","text":"⚠️ At least one ad has incorrect URL parameters."}}]},"thread_ts":{"export_enabled":true}}},"slack_notifier_v2_2":{"type":"slack_notifier_v2","logging_enabled":false,"x":1727,"y":412,"group":"group_3"},"for_each_v2_2":{"type":"for_each_v2","logging_enabled":false,"x":1002,"y":353,"group":"group_3"},"patch_json_v2_1":{"type":"patch_json_v2","logging_enabled":false,"x":1332,"y":432,"group":"group_3","inputs":{"patches":{"export_enabled":true,"data":[{"op":"replace","path":"/0/text/text","value":"Expected `{{input.value/pattern/regex}}` for _{{input.value/pattern/description}}_ but got `{{input.value/url}}`."},{"op":"replace","path":"/1/elements/0/url","value":"https://ads.tiktok.com/i18n/perf/creative?aadvid={{input.value/advertiser_id}}\u0026keyword={{input.value/id/id}}"}]},"data":{"export_enabled":true,"data":[{"type":"section","text":{"type":"mrkdwn","text":""}},{"type":"actions","elements":[{"type":"button","text":{"type":"plain_text","text":"Open in Ads Manager"},"url":""}]}]}}},"match_url_patterns_v2_1":{"type":"match_url_patterns_v2","logging_enabled":false,"x":617,"y":366,"group":"group_2","outputs":{"matched":{"title":"matched","description":"Triggered when matched"}}},"stop_1":{"type":"stop","logging_enabled":false,"x":21,"y":568,"inputs":{"stop":{"export_enabled":true}}},"start_1":{"type":"start","logging_enabled":false,"x":23,"y":473},"tik_tok_select_ad_account_ids_1":{"type":"tik_tok_select_ad_account_ids","logging_enabled":false,"x":34,"y":283,"inputs":{"ad_account_ids":{"export_enabled":true}}},"tik_tok_fetch_ads_1":{"type":"tik_tok_fetch_ads","logging_enabled":false,"x":523,"y":228,"group":"group_1","inputs":{"operational_status":{"export_enabled":true,"data":"RUNNING"}}},"patch_json_list_v2_1":{"type":"patch_json_list_v2","logging_enabled":false,"x":758,"y":229,"group":"group_1","inputs":{"value":{"export_enabled":true}}},"if_v2_2":{"type":"if_v2","logging_enabled":false,"x":992,"y":230,"group":"group_1","inputs":{"b":{"export_enabled":true,"data":[]},"condition":{"export_enabled":true,"data":"not_equal"}}}},"edges":["tik_tok_select_ad_account_ids_1.ad_account_ids:for_each_v2_1.items","start_1.start:for_each_v2_1.start","for_each_v2_1.done:delay_1.start","delay_1.delayed:for_each_v2_1.start","for_each_v2_2.done:for_each_v2_1.next","input_any_1.any:patch_json_list_v2_1.patches","build_pattern_v2_1.patterns:match_url_patterns_v2_1.patterns","match_url_patterns_v2_1.results:filter_v2_1.items","slack_notifier_v2_1.thread_ts:slack_notifier_v2_2.thread_ts","slack_select_conversation_id_1.conversation_id:slack_notifier_v2_2.conversation_id","slack_select_conversation_id_1.conversation_id:slack_notifier_v2_1.conversation_id","match_url_patterns_v2_1.matched:filter_v2_1.filter","filter_v2_1.filtered:if_v2_1.evaluate","slack_notifier_v2_1.sent:for_each_v2_2.start","patch_json_v2_1.data:slack_notifier_v2_2.blocks","for_each_v2_2.item:patch_json_v2_1.value","filter_v2_1.items:for_each_v2_2.items","filter_v2_1.items:if_v2_1.a","if_v2_1.true:slack_notifier_v2_1.send","patch_json_v2_1.patched:slack_notifier_v2_2.send","for_each_v2_2.do:patch_json_v2_1.patch","slack_notifier_v2_2.sent:for_each_v2_2.next","patch_json_list_v2_1.data_list:match_url_patterns_v2_1.urls","tik_tok_fetch_ads_1.ads:patch_json_list_v2_1.data_list","tik_tok_fetch_ads_1.fetched:patch_json_list_v2_1.patch","for_each_v2_1.item:tik_tok_fetch_ads_1.ad_account_id","for_each_v2_1.do:tik_tok_fetch_ads_1.fetch","patch_json_list_v2_1.patched:if_v2_2.evaluate","patch_json_list_v2_1.data_list:if_v2_2.a","if_v2_2.true:match_url_patterns_v2_1.match","if_v2_2.false:for_each_v2_1.next"],"groups":{"group_2":{"title":"Check UTMs","description":"","x":908,"y":483,"inputs":["match_url_patterns_v2_1.match","match_url_patterns_v2_1.urls"],"outputs":["filter_v2_1.items","filter_v2_1.filtered"]},"group_3":{"title":"Send Slack Message","description":"","x":1402,"y":482,"inputs":["for_each_v2_2.items","slack_notifier_v2_1.send"],"outputs":["for_each_v2_2.done"]},"group_1":{"title":"Get active URLs","description":"","x":668,"y":483,"inputs":["tik_tok_fetch_ads_1.ad_account_id","tik_tok_fetch_ads_1.fetch"],"outputs":["if_v2_2.true","if_v2_2.false","patch_json_list_v2_1.data_list"]}},"widgets":{"widget_1":{"title":"Slack Channel","description":"Select a Slack Channel or Conversation","position":3,"input":"slack_select_conversation_id_1.conversation_id"},"widget_2":{"title":"Run every","description":"The duration to delay the trigger (in Seconds)","position":5,"input":"delay_1.duration"},"widget_3":{"title":"Ad Accounts","description":"Select one or more TikTok Ad Accounts","position":0,"input":"tik_tok_select_ad_account_ids_1.ad_account_ids"},"widget_4":{"title":"Ad Status","description":"The operational status of the ads.\nRunning = Active campaign | Active Adset | Active ad","position":0,"icon":"las la-check-circle","input":"tik_tok_fetch_ads_1.operational_status"},"widget_5":{"title":"UTM Parameters","description":"The UTM pattern you want to check against.","position":3,"icon":"","input":"build_pattern_v2_1.patterns"}},"variables":{},"config":{"capture_inputs_enabled":false,"caching_enabled":false},"tags":[]}

How To

After creating the automation you are required to make a few selections and then hit “Run Automation”. The check will then take place on the specified weekday(s) at the specified time.

⚠️
Per default, all active ads in an account will be checked. If you want to be more specific in the campaign, ad set, or ad selection you can add filters to the automation following this Builder tutorial.

Step 1

Select an Ad Account

Notion image

Step 2

Select a Slack Channel, in which you would like to receive the notifications

Notion image

Step 3

Define how often you want the automation to run

Notion image

Step 4

Create a pattern for your UTM.

Notion image
Did this answer your question?
😞
😐
🤩

Last updated on March 14, 2023